import json

numbers = [1,2,3,4,7,123,24,63]

filename = 'numbers.json'
with open(filename,'w') as f:
    json.dump(numbers,f)